// 专题相关的mock数据
import { mock, Random } from 'mockjs'

// 获取专题列表
export const getSpecialList = mock({
  'code': 1,
  'msg': '操作成功',
  'data': {
    'specialList': {
      'total': '@integer(10, 50)',
      'per_page': 10,
      'current_page': 1,
      'last_page': '@integer(1, 5)',
      'data|10': [{
        'id': '@id',
        'title': '@ctitle(5, 20)',
        'flag': '@pick(["hot", "new", "recommend"])',
        'label': '@cword(2, 4)',
        'image': '@image("200x150", "#4A7BF7", "Special")',
        'banner': '@image("750x300", "#4A7BF7", "Banner")',
        'diyname': '@word(5, 10)',
        'description': '@cparagraph(1, 3)',
        'views': '@integer(100, 10000)',
        'comments': '@integer(0, 500)',
        'createtime': '@integer(1600000000, 1630000000)',
        'updatetime': '@integer(1600000000, 1630000000)',
        'items': '@integer(5, 50)'
      }]
    }
  }
})

// 获取专题详情
export const getSpecialDetail = mock({
  'code': 1,
  'msg': '操作成功',
  'data': {
    'specialInfo': {
      'id': '@id',
      'title': '@ctitle(5, 20)',
      'flag': '@pick(["hot", "new", "recommend"])',
      'label': '@cword(2, 4)',
      'image': '@image("200x150", "#4A7BF7", "Special")',
      'banner': '@image("750x300", "#4A7BF7", "Banner")',
      'diyname': '@word(5, 10)',
      'description': '@cparagraph(1, 3)',
      'content': '<p>@cparagraph(10, 20)</p><p>@cparagraph(10, 20)</p><p>@cparagraph(10, 20)</p>',
      'views': '@integer(100, 10000)',
      'comments': '@integer(0, 500)',
      'createtime': '@integer(1600000000, 1630000000)',
      'updatetime': '@integer(1600000000, 1630000000)',
      'items': '@integer(5, 50)'
    },
    'archivesList': {
      'total': '@integer(10, 50)',
      'per_page': 10,
      'current_page': 1,
      'last_page': '@integer(1, 5)',
      'data|10': [{
        'id': '@id',
        'eid': '@string("lower", 10)',
        'title': '@ctitle(10, 30)',
        'image': '@image("200x150", "#4A7BF7", "CMS")',
        'images': '@image("200x150"),@image("200x150"),@image("200x150")',
        'images_list|3': ['@image("200x150", "#4A7BF7", "CMS")'],
        'channel_id': '@integer(1, 10)',
        'channel': {
          'id': '@integer(1, 10)',
          'name': '@cword(2, 4)',
          'image': '@image("100x100", "#4A7BF7", "CMS")',
          'diyname': '@word(5, 10)',
          'items': '@integer(50, 200)'
        },
        'user_id': '@integer(1, 100)',
        'user': {
          'id': '@integer(1, 100)',
          'nickname': '@cname',
          'avatar': '@image("100x100", "#4A7BF7", "Avatar")'
        },
        'likes': '@integer(0, 1000)',
        'dislikes': '@integer(0, 100)',
        'comments': '@integer(0, 500)',
        'views': '@integer(100, 10000)',
        'create_date': '@date("yyyy-MM-dd")',
        'createtime': '@integer(1600000000, 1630000000)'
      }]
    }
  }
})